<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <meta name="viewport" content="width=device-width, initial-scale=1.0">
    <title>Document</title>
</head>
<body>
    <div class="father">
        <div class="page" data-page-number="1">
            <span >ppppppp</span>
            <span>89809348</span>
        </div>
        <div class="page" data-page-number="2">
            <span>2222222</span>
            <span>dadadadad</span>
        </div>
    </div>
    <button onclick="clone()">点我</button>
    <script>
      function clone() {
        const range = window.getSelection().getRangeAt(0)
        console.log(range.cloneContents().childNodes);
      }
    </script>
</body>
</html>